package com.boot.entity;

import lombok.Data;
import lombok.ToString;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

//需要加上 Component:将读取出来的配置放到bean中

@Data
@ConfigurationProperties(prefix = "user2")
@ToString
public class User {
    private Long id;

    private String userName;

    private String password;

    private String[] names;

    private Order order;//用户的订单

}
